﻿<%@ Page Title="" Language="C#" MasterPageFile="~/admincp/MasterPageEmpty.master"
    AutoEventWireup="true" CodeFile="nhapdiem.aspx.cs" Inherits="admincp_nhapdiem" %>

<%@ Register Src="wucSideBar.ascx" TagName="wucSideBar" TagPrefix="uc1" %>
<%@ Register Src="wucNavTop.ascx" TagName="wucNavTop" TagPrefix="uc2" %>
<asp:Content ID="Content1" ContentPlaceHolderID="cphHead" runat="Server">
    <style type="text/css">
        .nhapdiem
        {
            /*background-image: url(images/bg.png);*/
            border: 1px solid #6297BC;
            width: 30px;
        }
    </style>
    <script type="text/javascript">
        function CheckNumberInput(input) {
            if (input.value.match(/[^0-9,.]/g)) {
                input.value = input.value.replace(/[^0-9,.]/g, '');
            }

            if (input.value > 10) {
                input.value = "";
            }
            else if (input.value < 0) {
                input.value = "";
            }
        }
    </script>
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="cphTopBar" runat="Server">
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="cphSideBar" runat="Server">
    <uc1:wucSideBar ID="wucSideBar1" runat="server" />
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="cphNavTop" runat="Server">
    <uc2:wucNavTop ID="wucNavTop1" runat="server" />
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="cphContent" runat="Server">
    <div class="flat_area grid_4">
        <h2>
            Chọn năm học:</h2>
        <asp:DropDownList ID="ddlNamHoc" title="Chọn năm học" runat="server" AutoPostBack="True"
            OnSelectedIndexChanged="ddlNamHoc_SelectedIndexChanged">
        </asp:DropDownList>
        <br />
    </div>
    <div class="flat_area grid_4">
        <h2>
            Chọn học kỳ:</h2>
        <asp:DropDownList ID="ddlHocKy" title="Chọn học kỳ" runat="server">
        </asp:DropDownList>
        <br />
    </div>
    <div class="flat_area grid_4">
        <h2>
            Chọn lớp:</h2>
        <asp:DropDownList ID="ddlLopHoc" title="Chọn lớp" runat="server" OnSelectedIndexChanged="ddlLopHoc_SelectedIndexChanged"
            AutoPostBack="True">
        </asp:DropDownList>
        <br />
    </div>
    <div class="flat_area grid_4">
        <h2>
            Chọn môn học:</h2>
        <asp:DropDownList ID="ddlMonHoc" title="Chọn môn học" runat="server">
        </asp:DropDownList>
        <br />
    </div>
    <div class="flat_area grid_4">
        <%--<h2>
            Xác nhận:</h2>--%>
        <br />
        <button id="btnThemMoiNamHoc" onserverclick="XacNhanBatDauNhapDiem" runat="server"
            class="button_colour round_all">
            <img height="24" width="24" alt="Xác nhận" src="images/icon_confirm.png"><span>Xác nhận</span></button>
        <br />
    </div>
    <br />
    <br />
    <div class="flat_area grid_16">
        <h2>
            Chi tiết nhập điểm:</h2>
        <div class="toggle_container">
            <asp:ListView ID="lvNhapDiem" runat="server">
                <LayoutTemplate>
                    <table id="table" class="display table">
                        <thead>
                            <tr>
                                <th style="width: 1%">
                                    #
                                </th>
                                <th style="width: 5%">
                                    STT
                                </th>
                                <th style="width: 5%">
                                    Phù hiệu
                                </th>
                                <th style="width: 10%">
                                    Họ và tên
                                </th>
                                <th style="width: 8%" align="center">
                                    Điểm miệng
                                </th>
                                <th style="width: 8%" align="center">
                                    Điểm 15'
                                </th>
                                <th style="width: 8%" align="center">
                                    Điểm 15'
                                </th>
                                <th style="width: 8%" align="center">
                                    Điểm 15'
                                </th>
                                <th style="width: 8%" align="center">
                                    Điểm 1T
                                </th>
                                <th style="width: 8%" align="center">
                                    Điểm 1T
                                </th>
                                <th style="width: 8%" align="center">
                                    Điểm 1T
                                </th>
                                <th style="width: 8%" align="center">
                                    Điểm HKỳ
                                </th>
                            </tr>
                        </thead>
                        <tbody>
                            <asp:PlaceHolder ID="itemPlaceHolder" runat="server"></asp:PlaceHolder>
                        </tbody>
                    </table>
                </LayoutTemplate>
                <ItemTemplate>
                    <tr>
                        <td>
                            <asp:HiddenField ID="hdfMaHocSinh" Value='<%# Eval("MaHocSinh")%>' runat="server" />
                        </td>
                        <td align="right">
                            <b>
                                <%# Eval("SoThuTu")%></b>
                        </td>
                        <td>
                            <b>
                                <%# Eval("SoPhuHieu")%></b>
                        </td>
                        <td>
                            <%# Eval("TenHocSinh")%>
                        </td>
                        <td align="center">
                            <asp:TextBox ID="txtDiemMieng" onkeyup="CheckNumberInput(this)" onblur="CheckNumberInput(this)"
                                CssClass="nhapdiem" runat="server" Style="text-align: center" Width="30px"></asp:TextBox>
                        </td>
                        <td align="center">
                            <asp:TextBox ID="txtDiem15p1" onkeyup="CheckNumberInput(this)" onblur="CheckNumberInput(this)"
                                CssClass="nhapdiem" runat="server" Style="text-align: center" Width="30px"></asp:TextBox>
                        </td>
                        <td align="center">
                            <asp:TextBox ID="txtDiem15p2" onkeyup="CheckNumberInput(this)" onblur="CheckNumberInput(this)"
                                CssClass="nhapdiem" runat="server" Style="text-align: center" Width="30px"></asp:TextBox>
                        </td>
                        <td align="center">
                            <asp:TextBox ID="txtDiem15p3" onkeyup="CheckNumberInput(this)" onblur="CheckNumberInput(this)"
                                CssClass="nhapdiem" runat="server" Style="text-align: center" Width="30px"></asp:TextBox>
                        </td>
                        <td align="center">
                            <asp:TextBox ID="txtDiem1T1" onkeyup="CheckNumberInput(this)" onblur="CheckNumberInput(this)"
                                CssClass="nhapdiem" runat="server" Style="text-align: center" Width="30px"></asp:TextBox>
                        </td>
                        <td align="center">
                            <asp:TextBox ID="txtDiem1T2" onkeyup="CheckNumberInput(this)" onblur="CheckNumberInput(this)"
                                CssClass="nhapdiem" runat="server" Style="text-align: center" Width="30px"></asp:TextBox>
                        </td>
                        <td align="center">
                            <asp:TextBox ID="txtDiem1T3" onkeyup="CheckNumberInput(this)" onblur="CheckNumberInput(this)"
                                CssClass="nhapdiem" runat="server" Style="text-align: center" Width="30px"></asp:TextBox>
                        </td>
                        <td align="center">
                            <asp:TextBox ID="txtDiemHKy" onkeyup="CheckNumberInput(this)" onblur="CheckNumberInput(this)"
                                CssClass="nhapdiem" runat="server" Style="text-align: center" Width="30px"></asp:TextBox>
                        </td>
                    </tr>
                </ItemTemplate>
            </asp:ListView>
            <br />
        </div>
    </div>
    <div class="flat_area grid_8">
        <h2>
            Lưu nhập điểm:</h2>
        <button id="btnLuuLai" onserverclick="LuuNhapDiem" runat="server" class="button_colour round_all">
            <img height="24" width="24" alt="Lưu nhập điểm" src="images/icon_apply.png" /><span>Lưu
                nhập điểm</span></button>
    </div>
    <div class="flat_area grid_8">
        <h2>
            Xuất ra tập tin Excel:</h2>
        <button id="btnXuatExcel" onserverclick="XuatExcel" runat="server" class="button_colour round_all">
            <img height="24" width="24" alt="Xuất ra tập tin Excel" src="images/icon_excel.png" /><span>Xuất
                ra tập tin Excel</span></button>
    </div>
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="cphTemplateOption" runat="Server">
</asp:Content>
